import Vue from 'vue'
import {
    Message,
    Input,
    Dialog,
    Button,
    Select,
    Option,
    Dropdown,
    DropdownItem,
    DropdownMenu,
    Autocomplete,
    Loading,
    Table,
    TableColumn,
    Pagination,
    Popover,
    Popconfirm
} from 'element-ui'



// 修改全局的提示时间

// 修改全局的提示时间
Vue.prototype.$message = function (msg) {
    return Message({
        message: msg,
        duration: 1500
    })
}
Vue.prototype.$message.success = function (msg) {
    return Message.success({
        message: msg,
        duration: 1500
    })
}

Vue.prototype.$message.warning = function (msg) {
    return Message.warning({
        message: msg,
        duration: 1500
    })
}
Vue.prototype.$message.error = function (msg) {
    return Message.error({
        message: msg,
        duration: 1500
    })
}
Vue.prototype.$loading = Loading.service;
Vue.use(Input)
Vue.use(Loading.directive);
Vue.use(Dialog)
Vue.use(Button)
Vue.use(Select)
Vue.use(Option)
Vue.use(DropdownItem)
Vue.use(DropdownMenu)
Vue.use(Autocomplete)
Vue.use(Pagination)
Vue.use(Popconfirm)
Vue.use(Popover)
Vue.use(Table);
Vue.use(TableColumn);
Vue.use(Dropdown);